home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
SPACE 2
/
SPACE - Library 2 - Volume 1.iso
/
utility
/
681
/
d_sound
/
gfstst.gfa
(
.txt
)
next >
Wrap
GFA-BASIC Atari
|
1987-04-21
|
2KB
|
48 lines
REM ******************************************************
REM * Simple PLAYBACK Demo for GFA Basic version 2 and 3 *
REM * by A.R and D.A.W. (C)2-BIT systems LTD *
REM ******************************************************
REM * Reserve memory for code & sample *
REM * & allocate addresses for each *
REM **************************************
DIM a%(2000),b%(5000)
code%=VARPTR(a%(0))
sample%=VARPTR(b%(0))
REM ***************************
REM * Load code & Demo sample *
REM ***************************
PRINT "Loading Code..."
BLOAD "SOUND.EXE",code%
start%=code%+28
kilsnd%=code%+32
PRINT "Loading Sample."
BLOAD "replay.spl",sample%
REM *************************
REM * Sample data :- *
REM * length = 6940 bytes*
REM *************************
length%=6940+sample%
FOR speed%=12 TO 16
REM ******************************
REM * Poke Sample data into code *
REM ******************************
LPOKE code%+44,sample%
LPOKE code%+48,length%
LPOKE code%+40,speed%
REM *************************
REM * Now REPLAY the sample *
REM *************************
PRINT "Playing sample at speed ";speed%;" kHz"
CALL start%
PRINT
PRINT "doing ";speed%;" kHz"
PRINT
label:
x%=LPEEK(code%+56)
IF x%<>0
GOTO label
ENDIF
NEXT speed%
PRINT "Finished."
END